package br.com.glh.giza.entity;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.UniqueConstraint;

/**
 * The persistent class for the cor database table.
 * 
 */
@Entity
@Table(name = "cor", uniqueConstraints = {
		@UniqueConstraint(name = "UNQ_descricao", columnNames = { "descricao" }),
		@UniqueConstraint(name = "UNQ_abreviacao", columnNames = { "abreviacao" }) })
public class Cor extends AbstractEntity {
	private static final long serialVersionUID = 1L;

	@Basic(optional = false)
	@Column(name = "descricao", nullable = false, length = 255)
	private String descricao;

	@Basic(optional = false)
	@Column(name = "abreviacao", nullable = false, length = 2)
	private String abreviacao;

	@Basic(optional = true)
	@Column(name = "rgb", nullable = true)
	private Integer rgb;

	public Cor() {
	}

	public String getDescricao() {
		return descricao;
	}

	public void setDescricao(String descricao) {
		this.descricao = descricao;
	}

	public String getAbreviacao() {
		return abreviacao;
	}

	public void setAbreviacao(String abreviacao) {
		this.abreviacao = abreviacao;
	}

	public Integer getRgb() {
		return rgb;
	}

	public void setRgb(Integer rgb) {
		this.rgb = rgb;
	}

}